<template>
	<view>
		<bg-video></bg-video>
		<cu-custom bgColor="bg-main" :isBack="true">
			<block class="text-white" slot="content">教练详细</block>
		</cu-custom>
		
		<view class="cu-card case">
			<view class="cu-list menu-avatar">
				<view class="cu-item">
					<view v-if="amdjl.cover" class="cu-avatar round lg" :style="{ backgroundImage: `url(${amdjl.cover})` }"></view>
					<view class="content">
						<view class="flex justify-start">
							<text>{{amdjl.mdjlname}}</text>
						</view>
						
					</view>
				</view>
			</view>
		</view>
		
		<view class="padding-sm">
			<view class="rounded">
				<view class="padding bg-blue">
					<text class="text-white text-df">所在门店</text>
				</view>
				<view class="padding-sm">
					<view class="flex justify-center text-xl bg-white  padding">
						<text>{{astore.sname}}</text>
					</view>
					<!-- 轮播图 -->
					<view>
						<swiper class="screen-swiper" :indicator-dots="false" :circular="true" :autoplay="true" interval="2000"
							duration="500">
							<swiper-item v-for="(item,index) in astore.imgs" :key="index">
								<image :src="item" mode="aspectFill"></image>
							</swiper-item>
						</swiper>
					</view>
					<view class="padding text-lg">
						<text class="cuIcon-locationfill text-main"></text>
						<text class="margin-left-xs text-sm">
							<text>{{astore.sheng}}</text>
							<text>{{astore.shi}}</text>
							<text>{{astore.qu}}</text>
							<text>{{astore.address}}</text>
						</text>
					</view>
				</view>
			</view>
		</view>

	</view>
</template>

<script>
	export default {
		data: function() {
			return {
				amdjl: {},
				astore: {},
				lxmap: this.constant.lxmap,
				kczt: this.constant.kczt.KCZT,
				
			};
		},
		onShareAppMessage: function(){
			return {
				title: this.store.state.title,
				path: '/pages/first?id='+this.store.state.client.clientid
			}
		},
		onLoad: function(option) {
			this.amdjl.mdjlid = option.mdjlid;
			this.loadData();
		},
		methods: {
			loadData: function() {
				this.api("/mdjl/get").send({
					mdjlid: this.amdjl.mdjlid
				}).then(res => {
					this.amdjl = res.amdjl;
					this.astore = res.astore;
				});
			},

		}
	};
</script>
<style>
	.kctitle {
		position: absolute;
		bottom: 0;
		width: 100%;
		display: flex;
		align-items: start;
		min-height: 100rpx;
		justify-content: space-between;
		flex-direction: column;
	}

</style>